export const sendAjax = function (url) {
    return new Promise((resolve, reject) => {
        let xhr = new XMLHttpRequest()
        xhr.onreadystatechange = () => {
            if (xhr.readyState == 4) {
                if (xhr.status == 200) {
                    resolve(xhr.response)
                }
            }
        }
        xhr.open('GET', url)
        xhr.send()
    })
}